function [elements,processInfo] = InitializeSolutionStep...
    (elements,model,processInfo)
ne = model.countElements();
for i=1:ne
    e = model.getElement(i-1);
    f = e.getFace();
    ue = f.getUHatLocal();
    xi = e.getGaussPoint(0);
    B = zeros(3,6);
    B = e.computeB(f,B,xi);
    C = elements(i).constitutiveMatrix;
    %compute sigma
    if elements(i).isCrack==0
        elements(i).stress = C*B*ue;
    else
        epsilon = B*ue + elements(i).Gc*elements(i).Xi;
        elements(i).stress = C*epsilon;
    end
end
end
